package com.jarvis.zeng.design.pattern.composite.factory;

import com.jarvis.zeng.design.pattern.simple.factory.Shape;

public class ShapeFactory extends AbstractFactory {
    @Override
    public Shape getShape(String shape) {
        try{
            return (Shape)Class.forName(shape).newInstance();
        }catch(Exception e){
            e.printStackTrace();
        }
        return null;
    }

    @Override
    public Color getColor(String color) {
        return null;
    }
}
